class UserInfoModel {
  int? id;
  String? createBy;
  String? modifyBy;
  String? createTime;
  String? modifyTime;
  int? isDeleted;
  int? version;
  String? username;
  String? nickName;
  int? deptId;
  int? orgId;
  String? email;
  String? mobile;
  DateTime? birthday;
  int? status;
  String? lastLoginTime;
  int? sex;
  String? avatar;
  String? openid;
  String? realName;
  String? signature;
  String? theme;

  UserInfoModel(
      {this.id,
      this.createBy,
      this.modifyBy,
      this.createTime,
      this.modifyTime,
      this.isDeleted,
      this.version,
      this.username,
      this.nickName,
      this.deptId,
      this.orgId,
      this.email,
      this.mobile,
      this.birthday,
      this.status,
      this.lastLoginTime,
      this.sex,
      this.avatar,
      this.openid,
      this.realName,
      this.signature,
      this.theme});

  UserInfoModel.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    createBy = json['createBy'];
    modifyBy = json['modifyBy'];
    createTime = json['createTime'];
    modifyTime = json['modifyTime'];
    isDeleted = json['isDeleted'];
    version = json['version'];
    username = json['username'];
    nickName = json['nickName'];
    deptId = json['deptId'];
    orgId = json['orgId'];
    email = json['email'];
    mobile = json['mobile'];
    if (json['birthday'] != null) {
      birthday = DateTime.parse(json['birthday']).toLocal();
    }
    status = json['status'];
    lastLoginTime = json['lastLoginTime'];
    sex = json['sex'];
    avatar = json['avatar'];
    openid = json['openid'];
    realName = json['realName'];
    signature = json['signature'];
    theme = json['theme'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['id'] = this.id;
    data['createBy'] = this.createBy;
    data['modifyBy'] = this.modifyBy;
    data['createTime'] = this.createTime;
    data['modifyTime'] = this.modifyTime;
    data['isDeleted'] = this.isDeleted;
    data['version'] = this.version;
    data['username'] = this.username;
    data['nickName'] = this.nickName;
    data['deptId'] = this.deptId;
    data['orgId'] = this.orgId;
    data['email'] = this.email;
    data['mobile'] = this.mobile;
    if (this.birthday != null) {
      data['birthday'] = this.birthday!.toIso8601String();
    }
    data['status'] = this.status;
    data['lastLoginTime'] = this.lastLoginTime;
    data['sex'] = this.sex;
    data['avatar'] = this.avatar;
    data['openid'] = this.openid;
    data['realName'] = this.realName;
    data['signature'] = this.signature;
    data['theme'] = this.theme;
    return data;
  }
}
